
<template>
  <div class="root base-background-img">
    <div class="home">
      <router-link to="/">
        <img src="~@/assets/images/swiper/shouye.png">
      </router-link>
    </div>
    <div class="back">
      <router-link to="/youxiao">
        <img src="~@/assets/images/swiper/fanhui.png">
      </router-link>
    </div>
    <div class="shang">
        <img src="~@/assets/youxiaoxianjie/bihua/shang.png">
    </div>
    <div class="xia">
      <router-link to="/youxiao/bihua/bihuaxia">
        <img src="~@/assets/youxiaoxianjie/bihua/xia.png">
      </router-link>
    </div>
    <ul class="ul-item-content">
      <li class="li-item-content" v-for='(item, index) in tabs' :key="index" :class="{'active': item.isSelected}" @click="swiper(item)">
        <img :src="item.img" alt="">
      </li>
    </ul>
    <c-pdf @closePdf="closePdf" v-if="isshowpdf" :info="info" :infourl="pdfurl"></c-pdf>
  </div>
</template>

<script>
  export default {
    name: 'youxiao-bihuaindex',
    data () {
      return {
        isshowpdf: false,
        ishsowvideo: false,
        info: '',
        infourl: '',
        tabs: [{
          img: 'static/youxiao/bihua/a/1.png',
          url: 'static/youxiao/pdf/bihua/1/1.书写---点.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/2.png',
          url: 'static/youxiao/pdf/bihua/1/2.书写---横.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/3.png',
          url: 'static/youxiao/pdf/bihua/1/2.书写---竖.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/4.png',
          url: 'static/youxiao/pdf/bihua/1/3.书写---撇.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/5.png',
          url: 'static/youxiao/pdf/bihua/1/4.书写---捺.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/6.png',
          url: 'static/youxiao/pdf/bihua/1/2.书写---提.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/7.png',
          url: 'static/youxiao/pdf/bihua/1/3.书写---横折.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/8.png',
          url: 'static/youxiao/pdf/bihua/1/1.书写---横撇.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/9.png',
          url: 'static/youxiao/pdf/bihua/1/4.书写---横钩.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/10.png',
          url: 'static/youxiao/pdf/bihua/1/1.书写---横折钩.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/11.png',
          url: 'static/youxiao/pdf/bihua/1/4.书写---横折弯.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/12.png',
          url: 'static/youxiao/pdf/bihua/1/4.书写---横折弯钩.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/13.png',
          url: 'static/youxiao/pdf/bihua/1/2.书写---横折提.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/14.png',
          url: 'static/youxiao/pdf/bihua/1/3.书写---横斜钩.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/15.png',
          url: 'static/youxiao/pdf/bihua/1/4.书写---横撇弯钩.pdf',
          data: []
        },
        {
          img: 'static/youxiao/bihua/a/16.png',
          url: 'static/youxiao/pdf/bihua/1/2.书写---横折折撇.pdf',
          data: []
        }]
      }
    },
    methods: {
      swiper: function (item) {
        console.log(item)
        this.info = item.data
        this.pdfurl = item.url
        this.isshowpdf = true
      },
      closePdf: function () {
        this.isshowpdf = false
      }
    }
  }
</script>

<style scoped>
@import "~@/assets/style/base.css";
.root {
  background: url(~@/assets/youxiaoxianjie/bihua/bg.png);
}
.root > div {
  position: absolute; 
}
.ul-item-content {
  margin: 0;
  padding: 0;
  list-style-type: none;
  top: 230px;
  left: 190px;
  width: 1080px;
  height: 400px;
  position: absolute;
}
.li-item-content {
  cursor: pointer;
  float: left;
  margin: 15px 9px;
  position: initial;
  z-index: 10;
}
.home {
top: 54px;
    left: 57px;
}
.back {
    top: 153px;
    left: 57px;
}
.shang{
  top:100px;
  left:500px;
}
.xia{
  top:100px;
  left:640px;
}
</style>
